package 常用类.产生随机数Random.test;

import java.util.Random;

public class RandomTest01 {
    public static void main(String[] args) {
        Random random = new Random();
        int num1 = random.nextInt();
        System.out.println(num1);
        //产生0~100的随机数，不能产生101
        int a = random.nextInt(101);
        System.out.println(a);
    }
}
